<template>
	<view class="login_bg">
		<view class="like_top">
			<view class="back">
				<view class="back_img" @click="edit_ziliao()"><image src="../../static/images/left.png" mode="widthFix"></image></view>
			</view>
			<view class="like">编辑昵称</view>
			<view class="sub">保存</view>
		</view>
		<view class="send_dt">
			<input type="text" v-model="message"  maxlength="10" placeholder="" placeholder-style="font-size:1rem;color:#999;">
			<view class="send_num">{{ characterCount }} /10</view>
		</view>
	</view>
</template>

<script>
	export default {
	  data() {
	    return {
	       message: '',
		   isChecked: false
	    };
	  },
	  computed: {
	    characterCount() {
	      return this.message.length;
	    }
	  },
	  methods: {
		  edit_ziliao(){
		  	uni.navigateTo({
		  	            url:'/pages/edit_ziliao/edit_ziliao'
		  	        });
		  },
		  
		  
		  
		  
		  
	      handleFileChange(event) {
	        // 获取文件
	        const file = event.target.files[0];
	        // 可以在这里处理文件，比如预览等
	      },
	      uploadFile() {
	        // 触发文件选择
	        this.$refs.fileInput.click();
	        // 实际的上传逻辑
	        // ...
	      },
		  
		  handleSwitchChange(event) {
		        this.isChecked = event.detail.value;
		        // 这里可以执行你的逻辑，比如保存开关状态到服务器等
		        console.log('Switch is ' + (this.isChecked ? 'on' : 'off'));
				}
		  
	    }
	};
</script>

<style>
 @import "../../static/css/edit_nicheng.css";
</style>
